package com.chessgame.model;

/**
 * 棋子类型枚举
 */
public enum PieceType {
    RED_GENERAL("帅", true),
    RED_ADVISOR("仕", true),
    RED_ELEPHANT("相", true),
    RED_HORSE("马", true),
    RED_CHARIOT("车", true),
    RED_CANNON("炮", true),
    RED_SOLDIER("兵", true),
    
    BLACK_GENERAL("将", false),
    BLACK_ADVISOR("士", false),
    BLACK_ELEPHANT("象", false),
    BLACK_HORSE("马", false),
    BLACK_CHARIOT("车", false),
    BLACK_CANNON("炮", false),
    BLACK_SOLDIER("卒", false);

    private final String displayName;
    private final boolean isRed;

    PieceType(String displayName, boolean isRed) {
        this.displayName = displayName;
        this.isRed = isRed;
    }

    public String getDisplayName() {
        return displayName;
    }

    public boolean isRed() {
        return isRed;
    }
}